#pragma once

#include "njm_pipeline.hpp"
#include "njm_device.hpp"
#include "njm_game_obj.hpp"
#include "njm_camera.hpp"
#include "njm_frame_info.hpp"

#include <memory>
#include <vector>

namespace njm {

    class PointLightSystem
    {
    private:
        NjmDevice& njmDevice;
        VkPipelineLayout pipelineLayout;
        std::unique_ptr<NjmPipeline> njmPipeline;

        void createPipelineLayout(VkDescriptorSetLayout globalSetLayout);
        void createPipeline(VkRenderPass renderPass);

    public:
        PointLightSystem(NjmDevice &device, VkRenderPass renderPass, VkDescriptorSetLayout globalSetLayout);
        ~PointLightSystem();
        PointLightSystem(const PointLightSystem&) = delete;
        PointLightSystem &operator=(const PointLightSystem&) = delete;

        void render(FrameInfo &frameInfo);
        void update(FrameInfo &frameInfo, GlobalUbo &ubo);
    };
}